<?php
/**
 * Magento
 *
 * NOTICE OF LICENSE
 *
 * This source file is subject to the Academic Free License (AFL 3.0)
 * that is bundled with this package in the file LICENSE_AFL.txt.
 * It is also available through the world-wide-web at this URL:
 * http://opensource.org/licenses/afl-3.0.php
 * If you did not receive a copy of the license and are unable to
 * obtain it through the world-wide-web, please send an email
 * to license@magentocommerce.com so we can send you a copy immediately.
 *
 * DISCLAIMER
 *
 * Do not edit or add to this file if you wish to upgrade Magento to newer
 * versions in the future. If you wish to customize Magento for your
 * needs please refer to http://www.magentocommerce.com for more information.
 *
 * @category    design
 * @package     base_default
 * @copyright   Copyright (c) 2012 Magento Inc. (http://www.magentocommerce.com)
 * @license     http://opensource.org/licenses/afl-3.0.php  Academic Free License (AFL 3.0)
 */
?>
<?php
/**
 * @see Mage_Page_Block_Template_Links
 */	
	$login	=	new Mage_Customer_Block_Form_Login();
?>
<?php if (Mage::getSingleton('customer/session')->isLoggedIn()==0): ?>
	<a href="<?php echo $this->getBaseUrl()?>customer/account/create/" id="link-account-register" title="<?php echo $this->__('Register') ?>"><?php echo $this->__('Register') ?></a>
	<a href="<?php echo $this->getBaseUrl()?>customer/account/login/" id="link-account-login" title="<?php echo $this->__('Sign In') ?>"><?php echo $this->__('Sign In') ?></a>

	<div id="top-links" style="display:none">
		<form action="<?php echo $login->getPostActionUrl() ?>" method="post">
			<div class="block-content">
				<label for="mini-login"><?php echo $this->__('Email') ?> <em>*</em></label><input type="text" name="login[username]" id="mini-login" class="input-text autocompleteOff" />
				<label for="mini-password"><?php echo $this->__('Password') ?> <em>*</em></label><input type="password" name="login[password]" id="mini-password" class="input-text autocompleteOff" />
				<p class="required"><?php echo $this->__('* Required Fields') ?></p>

				<div class="login_forgotpassword">
					<a href="<?php echo $login->getForgotPasswordUrl() ?>" class="f-left"><?php echo $this->__('Forgot Your Password?') ?></a>
					
					<!--a href="<?php echo $this->getBaseUrl()?>customer/account/create/" title="<?php echo $this->__('Create an Account') ?>"><?php echo $this->__('Create an Account') ?></a-->
				</div>

				<div class="actions">
					<button type="submit" class="button"><span><span><?php echo $this->__('Login') ?></span></span></button>
				</div>
			</div>
		</form>
		<script type="text/javascript">
			jQuery(document).ready(function(){jQuery("input.autocompleteOff").attr("autocomplete","off");});
		</script>
	</div>
<?php else: ?>
	<a class="header_logout" href="<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_LINK).'customer/account/logout'; ?>" title="<?php echo $this->__('Logout') ?>"><?php echo $this->__('Logout') ?></a>
<?php endif ?>